package com.py.credit.service.impl;

import com.py.credit.common.Page;
import com.py.credit.dao.DeptUrlDao;
import com.py.credit.service.DeptUrlService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.LinkedHashMap;
import java.util.List;

@Service
public class DeptUrlServiceImpl implements DeptUrlService {

    @Autowired
    private DeptUrlDao deptUrlDao;

    @Override
    public List<String> selectAllUrl(long deptId) {
        return deptUrlDao.selectAllUrl(deptId);
    }

    @Override
    public List<LinkedHashMap> selectUrlForPage(long deptId, Page page) {
        return deptUrlDao.selectUrlForPage(deptId, page);
    }

    @Override
    public void insertUrl(String urlName, String url, long deptId) {
        deptUrlDao.insertUrl(urlName, url, deptId);
    }

    @Override
    public void modifyUrl(String urlName, String url, String status, String delFlag, String id) {
        deptUrlDao.modifyUrl(urlName, url, status, delFlag, id);
    }
}
